<include file="Public/header"/>
<if condition="$act eq 'edit'">
    <body class="body-bg">
    <div class="park-header">
        <div class="park-header__title">商铺管理</div>
        <div class="park-header__left park-back">
            <i class="iconfont icon-fanhui"></i>
        </div>
        <div class="park-header__right" onclick="sub_store();">确定</div>
    </div>
    <div class="container">
        <div class="park-row-list">
            <div class="park-row-item">
                <div class="park-row-item__left"><input type="text" id="store_name" placeholder="请输入新店名/档口编号" value="{:session('store_name')}"></div>
            </div>
        </div>
    </div>
    </body>
    <script src="__ROOT__/Public/Home/layer/layer.js"></script>
    <script>
        function sub_store(){
            var store_name = $('#store_name').val();
            if(!store_name){
                layer.open({
                    content:'请输入新店名/档口编号'
                    ,skin: 'msg'
                    ,time: 2 //2秒后自动关闭
                });
                return false;
            }
            $.post('/Business/User/store/',{'store_name':store_name},function(data){
                layer.open({
                    content:data.msg
                    ,skin: 'msg'
                    ,time: 2 //2秒后自动关闭
                });
            },'json');
        }
    </script>
    </html>
<else />
    <body class="body-bg">
    <div class="park-header">
        <div class="park-header__title">商铺管理</div>
        <div class="park-header__left" onclick="window.location='/Business/User/index/';">
            <i class="iconfont icon-fanhui"></i>
        </div>
    </div>
    <div class="container">
        <div class="park-row-list">
            <div class="park-row-item" onclick="window.location='/Business/User/store/act/edit/';">
                <div class="park-row-item__left">修改店铺/档口编号</div>
                <div class="park-row-item__right">
                    <i class="iconfont icon-gengduo"></i>
                </div>
            </div>
        </div>
    </div>
    </body>
    </html>
</if>